package com.hetao.assist.controller;

import com.github.pagehelper.Page;
import com.hetao.assist.model.JsonPage;

public class BaseController {

    protected  <T> JsonPage<T> convertPage(Page<T> page) {
        return new JsonPage<T>(page.getResult(), page.getTotal(),page.getPageNum(), page.getPageSize(), page.getPages());
    }
}
